/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package tagcloud.component;

import java.util.LinkedList;
import java.util.List;

/**
 *
 * @author thong
 */
public class Article {
    public List<Word> words;
        
    public Article()
    {
       words = new LinkedList<>();       
    }
    
    public double getWordFrequency(String word)
    {
        int result=0;
        for (Word w: words)
        {
            if (w.word.equals(word))
                return w.frequency;
        }
        return result;
    }
}
